<?php
namespace voxfa\executor;

require_once dirname(__FILE__)."/ExecutorInterface.php";
require_once dirname(__FILE__)."/ExecutorException.php";

class Executor implements executorInterface {
	
	public function run($command){
		$endline = exec($command,$output,$ret);
		
		if((int)$ret == 0)
			return $output;
			
		throw new executorException($output,$ret,$endline);
	}
}